package com.homework.action;

import java.util.List;

import com.homework.bean.Student;
import com.homework.dao.ShowStudentsDao;
import com.homework.daoImpl.ShowStudentsDaoImpl;
import com.opensymphony.xwork2.ActionSupport;

public class ShowAllStudentsAction extends ActionSupport {
	private static final long serialVersionUID = 1L;

	private List<Student> list;

	public List<Student> getList() {
		return list;
	}

	public void setList(List<Student> list) {
		this.list = list;
	}

	@Override
	public String execute() throws Exception {
		ShowStudentsDao show = new ShowStudentsDaoImpl();
		list = show.getAllStudents();
		return SUCCESS;
	}
}
